<?php
/* @var $this UserController */
/* @var $model User */

$this->breadcrumbs=array(
	'注册用户'=>array('index'),
	'管理',
);

$this->menu=array(
	array('label'=>'用户列表', 'url'=>array('index')),
	array('label'=>'新建用户', 'url'=>array('create')),
);

Yii::app()->clientScript->registerScript('search', "
$('.search-button').click(function(){
	$('.search-form').toggle();
	return false;
});
$('.search-form form').submit(function(){
	$('#user-grid').yiiGridView('update', {
		data: $(this).serialize()
	});
	return false;
});
");
?>

<?php //echo CHtml::link('Advanced Search','#',array('class'=>'search-button')); ?>
<div class="search-form" style="display:none">
<?php $this->renderPartial('_search',array(
	'model'=>$model,
)); ?>
</div><!-- search-form -->

<?php $this->widget('zii.widgets.grid.CGridView', array(
	'id'=>'user-grid',
	'dataProvider'=>$model->search(),
	//'filter'=>$model,
	'columns'=>array(
		'userId',
		'userName',
        //'createdBy',
		//'modifiedBy',
		//'modifiedOn',
		//'createdOn',
		//'companyId',
		//'roles',
		//'version',
		//'tagline',
		//'password',
		/**/
		//'avatar',
		//'jobTitle',
		//'email',
		//'emailPreference',
		//'website',
		//'active',
		//'lastLogin',
		//'lastIp',
		'uuid',
		'facebook',
		'twitter',
		//'openid',
		
		
		array(
			'class'=>'CButtonColumn',
		),
	),
)); ?>
